package com.kzx.blog.service.model;

import lombok.Data;

import javax.validation.constraints.*;

/**
 * @author kongz
 * @version 1.0 2021/12/14 9:46
 * @description 新增评论参数
 */
@Data
public class CommentAddParam {

    /*
    博客id
     */
    @Positive(message = "错误的博客id")
    private int blogId;

    /*
    评论人姓名
     */
    @NotEmpty(message = "评论人姓名不能为空")
    private String userName;

    /*
    评论人邮箱
     */
    @Email(message = "不合法的email格式")
    private String userEmail;

    /*
    评论内容
     */
    @Size(min = 1, max = 500, message = "长度不合法")
    private String content;

}
